package com.fxp.project.jiuselu.web.models.order.mapper;


import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.fxp.project.jiuselu.web.models.goods.entity.JslGoods;
import com.fxp.project.jiuselu.web.models.order.entity.SplitOrder;

import java.util.List;

/**
 * 拆分发货Mapper接口
 *
 * @author Jason.Wang
 * @date 2022-06-15
 */
public interface SplitOrderMapper  extends BaseMapper<SplitOrder>
{
    /**
     * 查询拆分发货
     *
     * @param id 拆分发货主键
     * @return 拆分发货
     */
    public SplitOrder selectSplitOrderById(Long id);

    /**
     * 查询拆分发货列表
     *
     * @param splitOrder 拆分发货
     * @return 拆分发货集合
     */
    public List<SplitOrder> selectSplitOrderList(SplitOrder splitOrder);

    /**
     * 通过orderId查询第一条物流信息
     * @param orderId
     * @return
     */
    public SplitOrder selectSplitOrderByOrderId(String orderId);

    /**
     * 新增拆分发货
     *
     * @param splitOrder 拆分发货
     * @return 结果
     */
    public int insertSplitOrder(SplitOrder splitOrder);

    /**
     * 修改拆分发货
     *
     * @param splitOrder 拆分发货
     * @return 结果
     */
    public int updateSplitOrder(SplitOrder splitOrder);

    /**
     * 删除拆分发货
     *
     * @param id 拆分发货主键
     * @return 结果
     */
    public int deleteSplitOrderById(Long id);

    /**
     * 批量删除拆分发货
     *
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteSplitOrderByIds(Long[] ids);
}
